%Load the data
data1 = [1, 1, 0, 0; 0, 0, 0, 1; 1, 0, 0, 0; 0, 0, 1, 1]';
% Create a Self-Organizing Map
dimension1 = 1;
dimension2 = 2;
net = selforgmap ([dimension1 dimension2]);
% Train the Network
[net, tr] = train (net, data1);
y = net (data1);
% View the Network
view(net)
%Plot results using different SOM plots
figure, plotsomtop (net)
figure, plotsomnc(net)
figure, plotsomnd(net)
figure, plotsomplanes(net)
figure, plotsomhits(net, data1)
figure, plotsompos(net, data1)
